/*
 * Copyright (c) 2017.
 * 项目名称： ctin
 * 文件名称： EnterInfoApi.java
 * Data：17-9-12 上午10:17
 * Author：asus
 */

package com.deram.ctin.serv.enter.api;

import com.deram.ctin.common.bean.PageResult;
import com.deram.ctin.serv.enter.filter.EnterPersonFilter;
import com.deram.ctin.serv.enter.entity.BaseUpdateInfo;
import com.deram.ctin.serv.enter.entity.EnterPerson;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * @Author: jtt
 * @Description:
 * @Date: 2017/9/12 10:17
 * @version: V1.0
 */
@FeignClient("serv-enter")
@RequestMapping("/enterPersonApi")
public interface EnterPersonApi {

    @PostMapping("/list")
    List<EnterPerson> list(@RequestBody EnterPersonFilter filter);

    @PostMapping("/save")
    EnterPerson save(@RequestBody EnterPerson param);

    @PostMapping("/search")
    PageResult<EnterPerson> search(@RequestBody EnterPersonFilter filter, @RequestParam("pageNo") Integer pageNo , @RequestParam("pageSize") Integer pageSize);

    @PostMapping("/delete")
    void delete(@RequestParam("id") Long id);

    @PostMapping("/saveList")
    void saveList(@RequestBody BaseUpdateInfo<EnterPerson> updateInfo);

}
